{{$shortStructName := .TableDetailResp.StructName}}
{{$lowerShortStructName := FirstLetterLower $shortStructName}}
import request from '@/utils/request'

// 查询{{.TableDetailResp.TableComment}}列表
export function list{{$shortStructName}}(query) {
  return request({
    url: '/{{.TableDetailResp.ModuleName}}/{{$lowerShortStructName}}/list',
    method: 'get',
    params: query
  })
}

// 查询{{.TableDetailResp.TableComment}}详细
export function get{{$shortStructName}}(id) {
  return request({
    url: '/{{.TableDetailResp.ModuleName}}/{{$lowerShortStructName}}/' + id,
    method: 'get'
  })
}

// 新增{{.TableDetailResp.TableComment}}
export function add{{$shortStructName}}(data) {
  return request({
    url: '/{{.TableDetailResp.ModuleName}}/{{$lowerShortStructName}}',
    method: 'post',
    data: data
  })
}

// 修改{{.TableDetailResp.TableComment}}
export function update{{$shortStructName}}(data) {
  return request({
    url: '/{{.TableDetailResp.ModuleName}}/{{$lowerShortStructName}}',
    method: 'put',
    data: data
  })
}

// 删除{{.TableDetailResp.TableComment}}
export function del{{$shortStructName}}(id) {
  return request({
    url: '/{{.TableDetailResp.ModuleName}}/{{$lowerShortStructName}}/' + id,
    method: 'delete'
  })
}
